﻿<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<!-- saved from url=(0089)http://169.254.158.100/zzdl/ContApply/Apply_list_do.asp?p_type=1&p_Applyno=10002010182564 -->
<HTML>
<HEAD><TITLE>合同申请明细</TITLE>
    <!--导入vue依赖-->
    <script th:src="@{/js/vue2.js}"></script>
    <!--导入axios依赖-->
    <script th:src="@{/js/axios.js}"></script>
    <!--导入分页组件-->
    <script th:src="@{/js/vuejs-paginate.js}"></script>
    <!--导入BootStrap框架所需的三个依赖-->
    <script th:src="@{/js/jquery.min.js}"></script>
    <META http-equiv=Content-Type content="text/html; charset=gb2312">

    <LINK href="css/style.css" rel=stylesheet>
    <META content="MSHTML 6.00.2900.5626" name=GENERATOR>
</HEAD>
<SCRIPT language=JAVASCRIPT>
    function back() {
        location.href = "Apply_daishenjihua.html";
    }
</SCRIPT>
<BODY>
<div id="app">
    <CENTER>
        <TABLE style="LINE-HEIGHT: 30px" cellSpacing=1 cellPadding=0 width="100%"
               bgColor=#336699 borderColorLight=#006699 border=0>
            <TBODY>
            <TR>
                <TD>
                    <TABLE cellSpacing=1 cellPadding=3 width="100%" border=0>
                        <TBODY>
                        <TR bgColor=#ffffff>
                            <TD align=middle width="100%" bgColor=#ffffff colSpan=20
                                height=22>
                                <H2><FONT color=#0070c0><B>合同申请明细</B> <A
                                        onclick=""
                                        href=""><IMG alt=帮助
                                                     src="img/help_a.gif" border=0></A>
                                </FONT></H2></TD>
                        </TR>
                        <TR class=t1>
                            <TD width="20%">合同申请编号：</TD>
                            <TD class=t2 width="30%">{{ contAppNum
                                }}</TD><!--<td>合同编号：</td>
  <td colspan=2>W20100040</td>-->
                            <TD width="20%">报价份数：</TD>
                            <TD class=t2 width="30%">{{ statQuote }}</TD>
                        </TR>
                        <TR class=t1>
                            <TD width="20%">最高报价（元）：</TD>
                            <TD class=t2 width="30%">{{ max }}</TD>
                            <TD width="20%">最低报价（元）：</TD>
                            <TD class=t2
                                width="30%">{{ min }}
                            </TD>
                        </TR>
                        </TBODY>
                    </TABLE>
                </TD>
            </TR>
            </TBODY>
        </TABLE>

        <TABLE style="LINE-HEIGHT: 30px" cellSpacing=1 cellPadding=0 width="100%"
               bgColor=#336699 borderColorLight=#006699 border=0>
            <TBODY>
            <TR>
                <TD>
                    <TABLE cellSpacing=1 cellPadding=3 width="100%" border=0 v-for="(item,index) in searchResult.data">
                        <TBODY>

                        <TR class=T1>
                            <TD noWrap align=middle colSpan=9>物资<B><FONT color=red>{{ index + 1 }}
                                &nbsp;</FONT></B><A
                                    href="javascript:alert('对应的需求计划详细')">{{ item.MATERIAL_NAME }}</A>
                                999个
                                <B>计划价（元/含税）</B><A
                                        href="javascript:alert('对应报价书详细')">
                                    报价明细信息</A></TD>
                        </TR>
                        <TR class=t1>
                            <TD noWrap align=middle width="20%">供应商</TD>
                            <TD noWrap align=middle>数量</TD>
                            <TD noWrap align=middle>单价<BR>（元/含税）</TD>
                            <TD noWrap align=middle>运杂费<BR>（元）</TD>
                            <TD noWrap align=middle>其它费用<BR>（元）</TD>
                            <TD noWrap align=middle>总计<BR>（元）</TD>
                            <TD noWrap align=middle width="12%">计划开始<BR>交货期</TD>
                            <TD noWrap align=middle>开始<BR>交货期</TD>
                            <TD noWrap align=middle>结束<BR>交货期</TD>
                        </TR>
                        <TR class=t2>
                            <TD width="20%"><A
                                    href="javascript:alert('对应供应商详细')"><FONT
                                    color=green>{{ item.COMPANY }}</FONT></A><BR></TD>
                            <TD align=right>{{ item.AMOUNT }}<BR></TD>
                            <TD align=right>{{ item.UNIT_PRICE }}<BR></TD>
                            <TD align=right>{{ item.MIX_PRICE }}<BR></TD>
                            <TD align=right>{{ item.OTHER_PRICE }}<BR></TD>
                            <TD align=right>{{ item.TOTAL_PRICE }}<BR></TD>
                            <TD align=right>{{ item.END_DATE }}</TD>
                            <TD align=middle>{{ item.END_DATE }}<BR></TD>
                            <TD align=middle>{{ item.END_DATE }}<BR></TD>
                        </TR>

                        <TR class=t1>
                            <TD noWrap align=middle><B>需求计划数量<B></B></B></TD>
                            <TD align=right colSpan=4>{{ num1 }}<BR></TD>
                            <TD noWrap align=middle><B>订货数量<B></B></B></TD>
                            <TD align=right colSpan=4>{{ num2 }}<BR></TD>
                        </TR>
                        <TR class=t1>
                            <TD align=middle>总金额（元）</TD>
                            <TD colSpan=8>{{ total }}<BR></TD>
                        </TR>
                        </TBODY>
                    </TABLE>
                </TD>
            </TR>
            </TBODY>
        </TABLE>
        </TD></TR></TBODY></TABLE></CENTER>
    <BR>
    <CENTER>
<!--        <INPUT @click="shenpi" type=button value=审批>-->
        <INPUT onclick="back()" type=button value=返回>
    </CENTER>
</div>
</BODY>

<script>
    var app = new Vue({
        el: "#app",
        data: {
            contAppId: -1,
            userName: '', // 当前登录用户
            nowDate: '', // 当前日期
            contAppNum: '', // 合同申请编号
            statQuote: 0, // 报价份数
            max: 0, // 最高报价
            min: 0, // 最低报价
            total: 0, // 总金额
            num1: 0, // 需求计划数量
            num2: 0, // 订货数量
            searchResult: {//后端响应的结果

            },
        },
        methods: {
            init() {
                axios.get('/contractApply/getbyid', {
                    params: {
                        id: this.contAppId
                    }
                }).then(result => {
                    this.searchResult = result.data
                    console.log(this.searchResult)
                    if (this.searchResult.data) {
                        this.contAppNum = this.searchResult.data[0].CONT_APP_NUM;
                        this.statQuote = this.searchResult.data[0].STAT_QUOTE;
                        this.max = this.searchResult.data[0].TOP_QUOTE;
                        this.min = this.searchResult.data[0].LOW_QUOTE;
                        this.total = this.searchResult.data[0].ALL_SUM_PRICE;
                        this.num1 = this.searchResult.data[0].AMOUNT;
                        this.num2 = this.searchResult.data[0].AMOUNT;

                    }
                })
            },
            shenpi() {
                sessionStorage.setItem('contAppId', this.contAppId);
                //获取数据
                const value = sessionStorage.getItem('contAppId');
                console.log(value);

                window.document.location = "Apply_caiwushenpi2.html";
            }
        },
        created() {
            this.contAppId = sessionStorage.getItem('contAppId');
            this.init();
        },

    })

</script>

</HTML>
